
NRpost equ          0
NRwrite equ         1

INT_VECTOR_SYSCALL equ 0x90

global write
global syscall_post

bits 32
[section .text]

;get_ticks:
;    mov eax, NRget_ticks
;    int INT_VECTOR_SYSCALL
;    ret

write: ;int (*)(int fd, void* buf, int count)
    mov eax, NRwrite
    mov ebx, [esp + 4] ;fd
    mov ecx, [esp + 8] ; buf
    mov edx, [esp + 12] ;count
    int INT_VECTOR_SYSCALL
    ret

syscall_post: ; void (*)(int function, int dest, MESSAGE* msg)
    mov eax, NRpost
    mov ebx, [esp + 4] ;function
    mov ecx, [esp + 8] ; dest
    mov edx, [esp + 12] ; msg
    int INT_VECTOR_SYSCALL
    ret
